package com.zk.nakedfowl.labelingRecord.pojo;

import com.fasterxml.jackson.annotation.JsonIgnoreProperties;
import com.zk.nakedfowl.basicData.pojo.Category;
import com.zk.nakedfowl.basicData.pojo.Stalls;
import com.zk.nakedfowl.basicData.pojo.Terminal;

import javax.persistence.*;
import java.io.Serializable;
/**
 * 实体类
 * @author Administrator
 *
 */
@Entity
@Table(name="labeling_record")
@JsonIgnoreProperties({"hibernateLazyInitializer","handler"})
public class Record implements Serializable{

	@Id
	private String id;//

	private String barcodeNumber;//条码编号
	private java.util.Date LabelingDate;//贴标时间
	private String barcodeMachineId;//脚标机编号
	private String stallsId;//屠宰档口id
	private String salesTerminalId;//销售去向id（即销售终端）
	private String poultryCategoryId;//所属禽类id
	private String createBy;//创建者（发放人员）
	private java.util.Date createDate;//创建时间

	@OneToOne(targetEntity = Category.class,fetch = FetchType.LAZY)
	@JoinColumn(name = "poultryCategoryId",referencedColumnName = "id",insertable = false,updatable = false)
	private Category category;

 	@OneToOne(targetEntity = Stalls.class,fetch = FetchType.LAZY)
	@JoinColumn(name = "stallsId",referencedColumnName = "id",insertable = false,updatable = false)
	private Stalls stalls;

	@OneToOne(targetEntity = Terminal.class,fetch = FetchType.LAZY)
	@JoinColumn(name = "salesTerminalId",referencedColumnName = "id",insertable = false,updatable = false)
	private Terminal terminal;

	public Terminal getTerminal() {
		return terminal;
	}

	public void setTerminal(Terminal terminal) {
		this.terminal = terminal;
	}

	public Stalls getStalls() {
		return stalls;
	}

	public void setStalls(Stalls stalls) {
		this.stalls = stalls;
	}

	public Category getCategory() {
		return category;
	}

	public void setCategory(Category category) {
		this.category = category;
	}

	public String getId() {
		return id;
	}
	public void setId(String id) {
		this.id = id;
	}

	public String getBarcodeNumber() {		
		return barcodeNumber;
	}
	public void setBarcodeNumber(String barcodeNumber) {
		this.barcodeNumber = barcodeNumber;
	}

	public java.util.Date getLabelingDate() {		
		return LabelingDate;
	}
	public void setLabelingDate(java.util.Date LabelingDate) {
		this.LabelingDate = LabelingDate;
	}

	public String getBarcodeMachineId() {		
		return barcodeMachineId;
	}
	public void setBarcodeMachineId(String barcodeMachineId) {
		this.barcodeMachineId = barcodeMachineId;
	}

	public String getStallsId() {		
		return stallsId;
	}
	public void setStallsId(String stallsId) {
		this.stallsId = stallsId;
	}

	public String getSalesTerminalId() {		
		return salesTerminalId;
	}
	public void setSalesTerminalId(String salesTerminalId) {
		this.salesTerminalId = salesTerminalId;
	}

	public String getPoultryCategoryId() {		
		return poultryCategoryId;
	}
	public void setPoultryCategoryId(String poultryCategoryId) {
		this.poultryCategoryId = poultryCategoryId;
	}

	public String getCreateBy() {		
		return createBy;
	}
	public void setCreateBy(String createBy) {
		this.createBy = createBy;
	}

	public java.util.Date getCreateDate() {		
		return createDate;
	}
	public void setCreateDate(java.util.Date createDate) {
		this.createDate = createDate;
	}


	
}
